package com.htn.common.core.constant;

/**
 * 权限相关通用常量
 * 
 * @author htn
 */
public class SecurityConstants
{
    /**
     * 令牌自定义标识
     */
    public static final String TOKEN_AUTHENTICATION = "Authorization";

    /**
     * 令牌前缀
     */
    public static final String TOKEN_PREFIX = "Bearer ";

    /**
     * 用户ID字段
     */
    public static final String DETAILS_USER_ID = "userId";

    /**
     * 用户名字段
     */
    public static final String DETAILS_USERNAME = "username";

    /**
     * 授权信息字段
     */
    public static final String AUTHORIZATION_HEADER = "authorization";

    /**
     * 请求来源
     */
    public static final String FROM_SOURCE = "from-source";

    /**
     * 内部请求
     */
    public static final String INNER = "inner";


    //hsmw_common的 内容

    /**
     * 角色的key
     **/
    public static final String ROLE_CLAIMS = "ROLE_";

    /**
     * rememberMe 为 false 的时候过期时间是1个小时
     */
    public static final long EXPIRATION = 60 * 60L;

    /**
     * rememberMe 为 true 的时候过期时间是7天
     */
    public static final long EXPIRATION_REMEMBER = 60 * 60 * 24 * 7L;

    /**
     * JWT签名密钥硬编码到应用程序代码中，应该存放在环境变量或.properties文件中。
     */
    public static final String JWT_SECRET_KEY = "C*F-JaNdRgUkXn2r5u8x/A?D(G+KbPeShVmYq3s6v9y$B&E)H@McQfTjWnZr4u7w";
//	public static final String JWT_SECRET_KEY = "aXNsZWVfaGFoYQ==";

    // JWT token defaults
    public static final String TOKEN_HEADER = "Authorization";
    public static final String TOKEN_TYPE = "JWT";

    // Swagger WHITELIST
    public static final String[] SWAGGER_WHITELIST = {
            "/swagger-ui.html",
            "/swagger-ui/*",
            "/swagger-resources/**",
            "/v2/api-docs",
            "/v3/api-docs",
            "/webjars/**"
    };

    // 登录接口 WHITELIST
    public static final String LOGIN_WHITELIST = "/api/auth/login";

    // 登录接口 WHITELIST
    public static final String GET_MOBILE_ANDROID = "/api/getMobileByAndroid";

    // 微信支付宝回调地址 WHITELIST
    public static final String GET_PAY_URL = "/api/payment/notifyUrl";

    // 微信支付宝回调地址 WHITELIST
    public static final String UNI_PAY_URL = "/api/payment/unipayBackUrl";

    // 司机排行榜
    public static final String GET_DRIVER_RANKING = "/api/andro/driver/findDriverScoreRanking";

    // 图片验证码接口 WHITELIST
    public static final String VERIFY_CODE = "/api/auth/verifyCode";
    // 短信验证码接口 WHITELIST
    public static final String SMS_CODE = "/api/pub/sms/sendSmsCode";
    // 微信登录步骤一  wxCOde
    public static final String WX_CODE = "/api/auth/wxCode";

    // 微信登录步骤二  wxCOde
    public static final String WX_LOGIN = "/api/auth/wxLogin";

    // PM微信登录步骤一  wxCOde
    public static final String WX_PM_CODE = "/api/auth/wxPMCode";

    // PM微信登录步骤二  wxCOde
    public static final String WX_PM_LOGIN = "/api/auth/wxPMLogin";


    // PM微信登录步骤一  wxCOde
    public static final String WX_SALE_CODE = "/api/auth/wxSaleCode";

    // PM微信登录步骤二  wxCOde
    public static final String WX_SALE_LOGIN = "/api/auth/wxSaleLogin";


    // PM微信登录步骤一  wxCOde
    public static final String WX_CONCRETE_CODE = "/api/auth/wxConcreteCode";

    // PM微信登录步骤二  wxCOde
    public static final String WX_CONCRETE_LOGIN = "/api/auth/wxConcreteLogin";


    // PM微信登录步骤一  wxCOde
    public static final String WX_TPLS_CODE = "/api/auth/wxTPLSPCode";

    // PM微信登录步骤二  wxCOde
    public static final String WX_TPLS_LOGIN = "/api/auth/wxTPSPLogin";




    // 二维码初始化
    public static final String WX_QR_INIT = "/api/forman/qrRealTimeVolume";

    // 二维码更新
    public static final String WX_QR_UPDATE = "/api/forman/selectVehicleProcessInfo";

    // 二维码更新
    public static final String WX_QR_CHECK = "/api/forman/checkOrderIdAndIdentify";

    // ANDRO微信登录步骤一  wxCOde
    public static final String WX_ANDRO_CODE = "/api/auth/wxAndroCode";

    // ANDRO微信登录步骤二  wxCOde
    public static final String WX_ANDRO_LOGIN = "/api/auth/wxAndroLogin";

    // 过滤ALL
    public static final String FILTER_ALL = "/api/**";

    private SecurityConstants() {
    }
}
